/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package modeles.servicesClient;

import java.util.List;
import javax.ws.rs.core.GenericType;
import modeles.Recette;

/**
 * Jersey REST client generated for REST resource:RecetteFacadeREST
 * [admin/recette]<br>
 * USAGE:
 * <pre>
 * ServicesRecettes client = new ServicesRecettes();
 * Object response = client.XXX(...);
 * // do whatever with response
 * client.close();
 * </pre>
 *
 * @author Fred
 */
public class ServicesRecettes extends Services {

    public ServicesRecettes() {
        super("recette");
    }

    public List<Recette> getRecettes() {
        return (List<Recette>) super.findAll(new GenericType<List<Recette>>() {
        });
    }

    public boolean ajouterRecette(Recette recette) {
        return super.create(recette);
    }

    public Recette trouverRecette(String id) {
        return super.findById(Recette.class, id);
    }

    public boolean modifierRecette(Recette recette, String id) {
        return super.edit(recette, id);
    }

    public Integer supprimerRecette(String id) {
        return super.remove(id);
    }
}
